package com.example.designpartten.memento;

import lombok.extern.slf4j.Slf4j;

@Slf4j
public class Orignal {

    public String state;

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public Memento createMemento(String state) {
        return new Memento(state);
    }

    public void restoreMemnto(Memento memento) {
        this.setState(memento.getState());
        log.info(getState());
    }
}